package banco;

import java.sql.Connection;
import java.sql.DriverManager;


public abstract class Conexao {
    
    public Connection conexao;
    
    public Conexao() {
        try {
            Class.forName("com.mysql.jdbc.Driver");
            conexao = DriverManager.getConnection("jdbc:mysql://localhost:3306/smartmarket", "root", "root");

        } catch (Exception e) {
            System.out.println(e.getMessage());
            conexao = null;

        }
    }
    
    public boolean status(){
        if(conexao == null){
            return false;
        }return true;
    }

}
